3.822 \(\int \frac{\sin (c+d x) \tan ^4(c+d x)}{a+a \sin (c+d x)} \, dx\)

Optimal. Leaf size=105 \[ -\frac{\tan ^5(c+d x)}{5 a d}+\frac{\tan ^3(c+d x)}{3 a d}-\frac{\tan (c+d x)}{a d}+\frac{\sec ^5(c+d x)}{5 a d}-\frac{2 \sec ^3(c+d x)}{3 a d}+\frac{\sec (c+d x)}{a d}+\frac{x}{a} \]

[Out]

x/a + Sec[c + d*x]/(a*d) - (2*Sec[c + d*x]^3)/(3*a*d) + Sec[c + d*x]^5/(5*a*d) - Tan[c + d*x]/(a*d) + Tan[c +
d*x]^3/(3*a*d) - Tan[c + d*x]^5/(5*a*d)

________________________________________________________________________________________

Rubi [A]  time = 0.129149, antiderivative size = 105, normalized size of antiderivative = 1., number of steps used = 8, number of rules used = 5, integrand size = 27, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.185, Rules used = {2839, 2606, 194, 3473, 8} \[ -\frac{\tan ^5(c+d x)}{5 a d}+\frac{\tan ^3(c+d x)}{3 a d}-\frac{\tan (c+d x)}{a d}+\frac{\sec ^5(c+d x)}{5 a d}-\frac{2 \sec ^3(c+d x)}{3 a d}+\frac{\sec (c+d x)}{a d}+\frac{x}{a} \]

Antiderivative was successfully verified.

[In]

Int[(Sin[c + d*x]*Tan[c + d*x]^4)/(a + a*Sin[c + d*x]),x]

[Out]

x/a + Sec[c + d*x]/(a*d) - (2*Sec[c + d*x]^3)/(3*a*d) + Sec[c + d*x]^5/(5*a*d) - Tan[c + d*x]/(a*d) + Tan[c +
d*x]^3/(3*a*d) - Tan[c + d*x]^5/(5*a*d)

Rule 2839

Int[((cos[(e_.) + (f_.)*(x_)]*(g_.))^(p_)*((d_.)*sin[(e_.) + (f_.)*(x_)])^(n_.))/((a_) + (b_.)*sin[(e_.) + (f_
.)*(x_)]), x_Symbol] :> Dist[g^2/a, Int[(g*Cos[e + f*x])^(p - 2)*(d*Sin[e + f*x])^n, x], x] - Dist[g^2/(b*d),
Int[(g*Cos[e + f*x])^(p - 2)*(d*Sin[e + f*x])^(n + 1), x], x] /; FreeQ[{a, b, d, e, f, g, n, p}, x] && EqQ[a^2
 - b^2, 0]

Rule 2606

Int[((a_.)*sec[(e_.) + (f_.)*(x_)])^(m_.)*((b_.)*tan[(e_.) + (f_.)*(x_)])^(n_.), x_Symbol] :> Dist[a/f, Subst[
Int[(a*x)^(m - 1)*(-1 + x^2)^((n - 1)/2), x], x, Sec[e + f*x]], x] /; FreeQ[{a, e, f, m}, x] && IntegerQ[(n -
1)/2] &&  !(IntegerQ[m/2] && LtQ[0, m, n + 1])

Rule 194

Int[((a_) + (b_.)*(x_)^(n_))^(p_), x_Symbol] :> Int[ExpandIntegrand[(a + b*x^n)^p, x], x] /; FreeQ[{a, b}, x]
&& IGtQ[n, 0] && IGtQ[p, 0]

Rule 3473

Int[((b_.)*tan[(c_.) + (d_.)*(x_)])^(n_), x_Symbol] :> Simp[(b*(b*Tan[c + d*x])^(n - 1))/(d*(n - 1)), x] - Dis
t[b^2, Int[(b*Tan[c + d*x])^(n - 2), x], x] /; FreeQ[{b, c, d}, x] && GtQ[n, 1]

Rule 8

Int[a_, x_Symbol] :> Simp[a*x, x] /; FreeQ[a, x]

Rubi steps

\begin{align*} \int \frac{\sin (c+d x) \tan ^4(c+d x)}{a+a \sin (c+d x)} \, dx &=\frac{\int \sec (c+d x) \tan ^5(c+d x) \, dx}{a}-\frac{\int \tan ^6(c+d x) \, dx}{a}\\ &=-\frac{\tan ^5(c+d x)}{5 a d}+\frac{\int \tan ^4(c+d x) \, dx}{a}+\frac{\operatorname{Subst}\left (\int \left (-1+x^2\right )^2 \, dx,x,\sec (c+d x)\right )}{a d}\\ &=\frac{\tan ^3(c+d x)}{3 a d}-\frac{\tan ^5(c+d x)}{5 a d}-\frac{\int \tan ^2(c+d x) \, dx}{a}+\frac{\operatorname{Subst}\left (\int \left (1-2 x^2+x^4\right ) \, dx,x,\sec (c+d x)\right )}{a d}\\ &=\frac{\sec (c+d x)}{a d}-\frac{2 \sec ^3(c+d x)}{3 a d}+\frac{\sec ^5(c+d x)}{5 a d}-\frac{\tan (c+d x)}{a d}+\frac{\tan ^3(c+d x)}{3 a d}-\frac{\tan ^5(c+d x)}{5 a d}+\frac{\int 1 \, dx}{a}\\ &=\frac{x}{a}+\frac{\sec (c+d x)}{a d}-\frac{2 \sec ^3(c+d x)}{3 a d}+\frac{\sec ^5(c+d x)}{5 a d}-\frac{\tan (c+d x)}{a d}+\frac{\tan ^3(c+d x)}{3 a d}-\frac{\tan ^5(c+d x)}{5 a d}\\ \end{align*}

Mathematica [A]  time = 0.643285, size = 191, normalized size = 1.82 \[ -\frac{\sec ^3(c+d x) \left (8 \sin (c+d x)-30 c \sin (2 (c+d x))-30 d x \sin (2 (c+d x))+\frac{89}{4} \sin (2 (c+d x))+16 \sin (3 (c+d x))-15 c \sin (4 (c+d x))-15 d x \sin (4 (c+d x))+\frac{89}{8} \sin (4 (c+d x))+\left (-90 c-90 d x+\frac{267}{4}\right ) \cos (c+d x)-16 \cos (2 (c+d x))-30 c \cos (3 (c+d x))-30 d x \cos (3 (c+d x))+\frac{89}{4} \cos (3 (c+d x))-23 \cos (4 (c+d x))-25\right )}{120 a d (\sin (c+d x)+1)} \]

Antiderivative was successfully verified.

[In]

Integrate[(Sin[c + d*x]*Tan[c + d*x]^4)/(a + a*Sin[c + d*x]),x]

[Out]

-(Sec[c + d*x]^3*(-25 + (267/4 - 90*c - 90*d*x)*Cos[c + d*x] - 16*Cos[2*(c + d*x)] + (89*Cos[3*(c + d*x)])/4 -
 30*c*Cos[3*(c + d*x)] - 30*d*x*Cos[3*(c + d*x)] - 23*Cos[4*(c + d*x)] + 8*Sin[c + d*x] + (89*Sin[2*(c + d*x)]
)/4 - 30*c*Sin[2*(c + d*x)] - 30*d*x*Sin[2*(c + d*x)] + 16*Sin[3*(c + d*x)] + (89*Sin[4*(c + d*x)])/8 - 15*c*S
in[4*(c + d*x)] - 15*d*x*Sin[4*(c + d*x)]))/(120*a*d*(1 + Sin[c + d*x]))

________________________________________________________________________________________

Maple [A]  time = 0.09, size = 166, normalized size = 1.6 \begin{align*} -{\frac{1}{6\,da} \left ( \tan \left ({\frac{dx}{2}}+{\frac{c}{2}} \right ) -1 \right ) ^{-3}}-{\frac{1}{4\,da} \left ( \tan \left ({\frac{dx}{2}}+{\frac{c}{2}} \right ) -1 \right ) ^{-2}}+{\frac{5}{8\,da} \left ( \tan \left ({\frac{dx}{2}}+{\frac{c}{2}} \right ) -1 \right ) ^{-1}}+2\,{\frac{\arctan \left ( \tan \left ( 1/2\,dx+c/2 \right ) \right ) }{da}}+{\frac{2}{5\,da} \left ( \tan \left ({\frac{dx}{2}}+{\frac{c}{2}} \right ) +1 \right ) ^{-5}}-{\frac{1}{da} \left ( \tan \left ({\frac{dx}{2}}+{\frac{c}{2}} \right ) +1 \right ) ^{-4}}+{\frac{1}{da} \left ( \tan \left ({\frac{dx}{2}}+{\frac{c}{2}} \right ) +1 \right ) ^{-2}}+{\frac{11}{8\,da} \left ( \tan \left ({\frac{dx}{2}}+{\frac{c}{2}} \right ) +1 \right ) ^{-1}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(sec(d*x+c)^4*sin(d*x+c)^5/(a+a*sin(d*x+c)),x)

[Out]

-1/6/d/a/(tan(1/2*d*x+1/2*c)-1)^3-1/4/d/a/(tan(1/2*d*x+1/2*c)-1)^2+5/8/d/a/(tan(1/2*d*x+1/2*c)-1)+2/a/d*arctan
(tan(1/2*d*x+1/2*c))+2/5/d/a/(tan(1/2*d*x+1/2*c)+1)^5-1/d/a/(tan(1/2*d*x+1/2*c)+1)^4+1/d/a/(tan(1/2*d*x+1/2*c)
+1)^2+11/8/a/d/(tan(1/2*d*x+1/2*c)+1)

________________________________________________________________________________________

Maxima [B]  time = 1.69175, size = 429, normalized size = 4.09 \begin{align*} \frac{2 \,{\left (\frac{\frac{\sin \left (d x + c\right )}{\cos \left (d x + c\right ) + 1} - \frac{46 \, \sin \left (d x + c\right )^{2}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{2}} - \frac{13 \, \sin \left (d x + c\right )^{3}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{3}} + \frac{100 \, \sin \left (d x + c\right )^{4}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{4}} + \frac{35 \, \sin \left (d x + c\right )^{5}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{5}} - \frac{30 \, \sin \left (d x + c\right )^{6}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{6}} - \frac{15 \, \sin \left (d x + c\right )^{7}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{7}} + 8}{a + \frac{2 \, a \sin \left (d x + c\right )}{\cos \left (d x + c\right ) + 1} - \frac{2 \, a \sin \left (d x + c\right )^{2}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{2}} - \frac{6 \, a \sin \left (d x + c\right )^{3}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{3}} + \frac{6 \, a \sin \left (d x + c\right )^{5}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{5}} + \frac{2 \, a \sin \left (d x + c\right )^{6}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{6}} - \frac{2 \, a \sin \left (d x + c\right )^{7}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{7}} - \frac{a \sin \left (d x + c\right )^{8}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{8}}} + \frac{15 \, \arctan \left (\frac{\sin \left (d x + c\right )}{\cos \left (d x + c\right ) + 1}\right )}{a}\right )}}{15 \, d} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sec(d*x+c)^4*sin(d*x+c)^5/(a+a*sin(d*x+c)),x, algorithm="maxima")

[Out]

2/15*((sin(d*x + c)/(cos(d*x + c) + 1) - 46*sin(d*x + c)^2/(cos(d*x + c) + 1)^2 - 13*sin(d*x + c)^3/(cos(d*x +
 c) + 1)^3 + 100*sin(d*x + c)^4/(cos(d*x + c) + 1)^4 + 35*sin(d*x + c)^5/(cos(d*x + c) + 1)^5 - 30*sin(d*x + c
)^6/(cos(d*x + c) + 1)^6 - 15*sin(d*x + c)^7/(cos(d*x + c) + 1)^7 + 8)/(a + 2*a*sin(d*x + c)/(cos(d*x + c) + 1
) - 2*a*sin(d*x + c)^2/(cos(d*x + c) + 1)^2 - 6*a*sin(d*x + c)^3/(cos(d*x + c) + 1)^3 + 6*a*sin(d*x + c)^5/(co
s(d*x + c) + 1)^5 + 2*a*sin(d*x + c)^6/(cos(d*x + c) + 1)^6 - 2*a*sin(d*x + c)^7/(cos(d*x + c) + 1)^7 - a*sin(
d*x + c)^8/(cos(d*x + c) + 1)^8) + 15*arctan(sin(d*x + c)/(cos(d*x + c) + 1))/a)/d

________________________________________________________________________________________

Fricas [A]  time = 1.39791, size = 258, normalized size = 2.46 \begin{align*} \frac{15 \, d x \cos \left (d x + c\right )^{3} + 23 \, \cos \left (d x + c\right )^{4} - 19 \, \cos \left (d x + c\right )^{2} +{\left (15 \, d x \cos \left (d x + c\right )^{3} - 8 \, \cos \left (d x + c\right )^{2} + 1\right )} \sin \left (d x + c\right ) + 4}{15 \,{\left (a d \cos \left (d x + c\right )^{3} \sin \left (d x + c\right ) + a d \cos \left (d x + c\right )^{3}\right )}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sec(d*x+c)^4*sin(d*x+c)^5/(a+a*sin(d*x+c)),x, algorithm="fricas")

[Out]

1/15*(15*d*x*cos(d*x + c)^3 + 23*cos(d*x + c)^4 - 19*cos(d*x + c)^2 + (15*d*x*cos(d*x + c)^3 - 8*cos(d*x + c)^
2 + 1)*sin(d*x + c) + 4)/(a*d*cos(d*x + c)^3*sin(d*x + c) + a*d*cos(d*x + c)^3)

________________________________________________________________________________________

Sympy [F(-1)]  time = 0., size = 0, normalized size = 0. \begin{align*} \text{Timed out} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sec(d*x+c)**4*sin(d*x+c)**5/(a+a*sin(d*x+c)),x)

[Out]

Timed out

________________________________________________________________________________________

Giac [A]  time = 1.3074, size = 176, normalized size = 1.68 \begin{align*} \frac{\frac{120 \,{\left (d x + c\right )}}{a} + \frac{5 \,{\left (15 \, \tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right )^{2} - 36 \, \tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right ) + 17\right )}}{a{\left (\tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right ) - 1\right )}^{3}} + \frac{3 \,{\left (55 \, \tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right )^{4} + 260 \, \tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right )^{3} + 450 \, \tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right )^{2} + 300 \, \tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right ) + 71\right )}}{a{\left (\tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right ) + 1\right )}^{5}}}{120 \, d} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sec(d*x+c)^4*sin(d*x+c)^5/(a+a*sin(d*x+c)),x, algorithm="giac")

[Out]

1/120*(120*(d*x + c)/a + 5*(15*tan(1/2*d*x + 1/2*c)^2 - 36*tan(1/2*d*x + 1/2*c) + 17)/(a*(tan(1/2*d*x + 1/2*c)
 - 1)^3) + 3*(55*tan(1/2*d*x + 1/2*c)^4 + 260*tan(1/2*d*x + 1/2*c)^3 + 450*tan(1/2*d*x + 1/2*c)^2 + 300*tan(1/
2*d*x + 1/2*c) + 71)/(a*(tan(1/2*d*x + 1/2*c) + 1)^5))/d